
cachepool=cachepool
datapool=datapool

ceph osd tier add $datapool $cachepool
ceph osd tier cache-mode $cachepool writeback
ceph osd tier set-overlay $datapool $cachepool

ceph osd pool set $cachepool hit_set_type bloom

ceph osd pool set $cachepool hit_set_count 60
ceph osd pool set $cachepool hit_set_period 60

#460G
size=`expr 5000 \* 1024 \* 1024 \* 1024`
ceph osd pool set $cachepool target_max_bytes $size

#objs=`expr $size / 8192`
ceph osd pool set $cachepool target_max_objects 0

ceph osd pool set $cachepool cache_target_dirty_ratio 0.8
#ceph osd pool set cachepool cache_target_dirty_high_ratio 0.6

ceph osd pool set $cachepool cache_target_full_ratio 0.95


ceph osd pool set $cachepool cache_min_flush_age 300
ceph osd pool set $cachepool cache_min_evict_age 300

#ceph osd pool set ${cachepool} min_read_recency_for_promote 30
#ceph osd pool set ${cachepool} min_write_recency_for_promote 30
